<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>方圆小程序后台</title>
  <link rel="stylesheet" href="layui/css/layui.css">
  <link rel="stylesheet" href="css/public.css">
  <style>
  input[type="text"]:focus{
    border:1px solid #66afe9;
    box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);
  }
  input[type="password"]:focus{
    border:1px solid #66afe9;
    box-shadow: inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);
  }
</style>
</head>
<body>
  <div class="LoginBox">
    <div class="LoginLogoBox">
      <a href="/" class="loginTitle">
        <img src="images/login-new-logo.gif">
      </a>
      <span class="loginLogin">登录</span>
    </div>
    <div class="login-input-box">
      <div class="form-group">
        <div class="input-group login-border-radius">
          <div class="input-group-addon login-png">
            <img src="images/zhanghao.png" class="loginI">
          </div>
          <input type="text" class="form-control login-input" placeholder="账号" style="line-height: 32px;" id="zhanghao">
        </div>
      </div>
      <div class="form-group">
        <div class="input-group login-border-radius">
          <div class="input-group-addon login-png">
            <img src="images/mima.png" class="loginI">
          </div>
          <input type="password" class="form-control login-input" placeholder="请输入密码" style="line-height: 32px;" id="pwd">
        </div>
      </div>
      <div>
        <label class="lable99 zhanghao tips">请输入账号</label>
        <label class="lable99 pwd tips">请输入密码</label>
      </div>
      <div class="checkbox">
        <label><input type="checkbox" value="on">下次自动登录</label>
      </div>
      <div type="button" class="login-btn login-border-radius" onclick="doLogin()">登录</div>
      <div class="login-forget-register">
        <a href="tencent://message/?uin=738104561&Site=qq&Menu-=yes" target="blank" class="login-forget">忘记密码</a>|
        <a title="点击这里给我发消息" href="tencent://message/?uin=738104561&Site=qq&Menu-=yes" target="blank" class="login-register">申请账号</a>
      </div>
    </div>
  </div>

  <script src="layui/layui.js"></script>
  <script src="js/jquery.min.js"></script>
  <script>

    layui.use('element', function(){
      var element = layui.element;
    });

    $("input").focus(function(){
      $(".tips").hide();
    });

    function doLogin(){

      var zhanghao = $("#zhanghao").val();
      var pwd = $("#pwd").val();

      if(zhanghao.length==0){
        $(".zhanghao").show();
        return;
      }else if(pwd.length==0){
        $(".pwd").show();
        return;
      }
    }
  </script>
</body>
</html>